Method and apparatus for responding to question, and storage medium

ABSTRACT

According to embodiments of the present disclosure, a method and an apparatus for responding to a question, and a storage medium are provided. The method includes: determining a question characteristic representation corresponding to a question for an object; determining a comment characteristic representation corresponding to a first comment for the object; generating a first target characteristic representation by utilizing the question characteristic representation and the comment characteristic representation; and determining an answer for the question based on the first target characteristic representation.

CROSS-REFERENCE TO RELATED APPLICATION

The present application is based upon and claims priority to ChinesePatent Application No. 201811506468.2, filed on Dec. 10, 2018, theentirety contents of which are incorporated herein by reference.

FIELD

Embodiments of the present disclosure mainly relate to a field ofartificial intelligence, and more particularly to a method and anapparatus for responding to a question, and a computer readable storagemedium.

BACKGROUND

With development of the information age, lots of users may upload theirown messages or comments to a specific object over the Internet. On onehand, these messages or comments enrich content of the Internet; on theother hand, these messages and comments may objectively help other usersto further understand quality and characteristics of a message and acomment target. In a scenario such as electronic commerce, a user mayalso ask his or her own question for a specific object and expect toobtain an accurate answer for the question quickly. Therefore, how toaccurately respond to the questions raised by users has become a hottopic of concern.

SUMMARY

According to exemplary embodiments of the present disclosure, a methodfor responding to a question is provided.

In embodiments of the present disclosure, there is provided a method forresponding to a question. The method includes determining a questioncharacteristic representation corresponding to a question for an object;determining a comment characteristic representation corresponding to afirst comment for the object; generating a first target characteristicrepresentation by utilizing the question characteristic representationand the comment characteristic representation; and determining an answerfor the question based on the first target characteristicrepresentation.

In embodiments of the present disclosure, there is provided an apparatusfor responding to a question. The apparatus includes: a questioncharacteristic representation determining module, a commentcharacteristic representation determining module, a targetcharacteristic representation determining module and an answerdetermining module. The question characteristic representationdetermining module is configured to determine a question characteristicrepresentation corresponding to a question for an object. The commentcharacteristic representation determining module is configured todetermine a comment characteristic representation corresponding to afirst comment for the object. The target characteristic representationdetermining module is configured to generate a first targetcharacteristic representation by utilizing the question characteristicrepresentation and the comment characteristic representation. The answerdetermining module is configured to determine an answer for the questionbased on the first target characteristic representation.

In embodiments of the present disclosure, there is provided a computerreadable storage medium having computer programs stored thereon. Whenthe computer programs are executed by a processor, a method forresponding to a question according to embodiments of the presentdisclosure is implemented. The method includes: determining a questioncharacteristic representation corresponding to a question for an object;determining a comment characteristic representation corresponding to afirst comment for the object; generating a first target characteristicrepresentation by utilizing the question characteristic representationand the comment characteristic representation; and determining an answerfor the question based on the first target characteristicrepresentation.

It should be understood that, descriptions in Summary of the presentdisclosure are not intended to limit an essential or important featurein embodiments of the present disclosure, and are also not construed tolimit the scope of the present disclosure. Other features of the presentdisclosure will be easily understood by following descriptions.

BRIEF DESCRIPTION OF THE DRAWINGS

The above and other features, advantages and aspects of respectiveembodiments of the present disclosure will become more apparent withreference to accompanying drawings and following detailed illustrations.In the accompanying drawings, the same or similar numeral referencesrepresent the same or similar elements, in which:

FIG. 1 is a schematic diagram illustrating an exemplary scene in which aplurality of embodiments of the present disclosure may be implemented;

FIG. 2 is a flow chart illustrating a procedure for responding to aquestion according to embodiments of the present disclosure;

FIG. 3 is a schematic diagram illustrating a system for responding to aquestion according to embodiments of the present disclosure;

FIG. 4 is a flow chart illustrating a procedure for determining ananswer for a question according to embodiments of the presentdisclosure;

FIG. 5 is a block diagram illustrating an apparatus for responding to aquestion according to embodiments of the present disclosure; and

FIG. 6 is a block diagram illustrating a computing device being capableof implementing a plurality of embodiments of the present disclosure.

DETAILED DESCRIPTION

Description will be made in detail below to embodiments of the presentdisclosure with reference to accompanying drawings. Some implementationsof embodiments of the present disclosure are illustrated in theaccompanying drawings. It should be understood that, the presentdisclosure may be implemented in various ways, and is not limited to theembodiments described herein. On the contrary, those embodimentsprovided are merely for a more thorough and complete understanding ofthe present disclosure. It should be understood that, the accompanyingdrawings and embodiments of the present disclosure are merely forexemplary purposes, and is not used to limit the protection scope of thepresent disclosure.

In the description of embodiments of the present disclosure, terms suchas “include” and its equivalents should be understood as an inclusivemeaning, i.e. “include but not limited to”. Terms such as “based on”should be understood as “at least partially based on”. Terms such as “anembodiment” or “the embodiment” should be understood as “at least oneembodiment”. Terms such as “first”, “second” and the like may representdifferent or same objects. Other explicit and implicit definitions mayalso be included below.

As discussed above, a user may usually ask his/her own question for aspecific object over the Internet, and expect to obtain an accurateanswer quickly for the question. There have been solutions for answeringuser's question through intelligent question and answer robots. However,such questions should be in a single scenario, where such questionsintelligently are responded merely on a particular dimension. Forexample, some robots for intelligent shopping may merely respond to aspecific dimension of a product (such as, size information, logisticsinformation, price information, etc.). Such intelligent question andanswer robots are merely based on a specific rule, so it is difficult tocover other dimensions that are not covered by the rule.

According to embodiments of the present disclosure, a method forresponding to a question is provided. In the method, a question for aspecific object is converted to a question characteristic representationcorresponding to the question, and a comment for the specific object isalso converted to a comment characteristic representation correspondingto the comment. Further, a target characteristic representation isgenerated based on the question characteristic representation and thecomment characteristic representation, and an answer for the question isdetermined based on the target characteristic representation. Thesolution of the present disclosure may integrate questions and commentstogether for consideration when a response is made for the question,thus improving accuracy for responding to a question.

Embodiments of the present disclosure are described in detail below withreference to the accompanying drawings. FIG. 1 is a schematic diagramillustrating an exemplary scene 100 in which a plurality of embodimentsof the present disclosure may be implemented. In the exemplary scene100, a computing device 130 may receive a question 110 for an object. Insome embodiments, the object may be any suitable type. In someembodiments, the question 110 is a binary classification question forthe object, that is, the answer is “yes” or “no”. For example, in FIG.1, an exemplary question 110 may be a question for a dress, which is“Can this dress be worn by a little girl?”, and the answer is usually“yes” or “no”.

In some embodiments, the question 110 may be sent the computing device130 in a wire communication way or in a wireless communication way. Insome embodiments, the computing device 130 may also receive the question110 inputted by the user via an input device coupled to the computingdevice 130.

As illustrated in FIG. 1, the computing device 130 may also receive oneor more comments such as comments 120-1, 120-2, . . . , 120-M for theobject. For describing conveniently, the plurality of comments 120-1,120-2, . . . , 120-M may be collectively referred as comment 120. Insome embodiments, the computing device 130 may obtain the comment 120for the object from a comment database locating in the computing device130 or a comment database locating outside the computing device 130. Insome embodiments, the computing device 130 may also extract the comment120 for the object automatically from a product page associated with theobject. For example, an exemplary comment 120-1 illustrated in FIG. 1may be “My 3 years old girl loved it”.

The computing device 130 may determine an answer 140 for the question110 based on the received question 110 and the received comment 120. Forexample, in the example of FIG. 1, the computing device 130 maydetermine that the answer 140 for the question 110 “Can this dress beworn by a little girl?” is “yes” by utilizing the method for respondingto a question of the present disclosure and based on characteristicrepresentations of the question 110 and the comment 120. It should beunderstood that, the illustrated question, the illustrated comment andthe illustrated answer are merely an example, and the question and thecorresponding comment may be changed based on an actual condition, whichare not limited by the scope of the present disclosure.

A procedure for responding to a question will be described in moredetail below with reference to FIG. 2 and FIG. 3. FIG. 2 is a flow chartillustrating a procedure 200 for responding to a question according tosome embodiments of the present disclosure, and FIG. 3 is a schematicdiagram illustrating a system 300 for determining an answer for aquestion according to embodiments of the present disclosure. Theprocedure 200 may be implemented by the computing device 130 illustratedin FIG. 1. For describing conveniently, the procedure 200 will bedescribed with reference to FIG. 1 and FIG. 3.

At block 202, the computing device 130 determines a questioncharacteristic representation corresponding to a question 110 for anobject. In detail, the computing device 130 may perform a segmentationon the question 110 to determine a first vocabulary characteristicrepresentation. As illustrated in FIG. 3, when the question 110 isreceived, the computing device 130 may perform the segmentation on thereceived question 110 by utilizing a segmentation model. When thequestion is pinyin characters such as English or Latin, a segmentedresult is respective segmented words; when the question is Chinese orJapanese, a segmented result is respective segmented vocabularies. Indetail, in an example illustrated in FIG. 3, a segmented result of thequestion 110, i.e., the obtained segments may be “can”, “this”, “dress”,“be”, “worn”, “by”, “a”, “little”, and “girl”. It should be understoodthat, any suitable segmentation technology may be employed to performthe segmentation on the question 110, which is not elaborated herein.

It is assumed that a question includes n English words (or n Chinesewords). When an English word (or a Chinese word) at the i^(-th) indexposition is defined as v_(i), the question with the length is n may berepresented as v_(1:n)=[v₁, v₂, . . . , v_(n)]. In some embodiments, thecomputing device 130 may define a number corresponding to each Englishword v_(i). In detail, for example, the number is a vector with adimension d, i.e., v_(i)∈

^(d). For example, in an example of FIG. 3, a first vocabularycharacteristic representation 302 of the question 110 may be representedas [v₁ ^(q), v₂ ^(q), . . . , v_(n) ^(q)], where v_(i) ^(q) representsthe i^(-th) word in a question q file.

In some embodiments, the computing device 130 may determine a questioncharacteristic representation 310 based on the first vocabularycharacteristic representation 302. In some embodiments, the computingdevice 130 may use the first vocabulary characteristic representation302 as the question characteristic representation 310 directly.

In some embodiments, the computing device 130 may apply the firstvocabulary characteristic representation 302 to a context extractionmodel, to obtain the question characteristic representation. The contextextraction model is configured to determine a context relationship amongelements in the first vocabulary characteristic representation. Forexample, the computing device 130 may extract context information of thequestion 110 by utilizing a Bi-directional long and short term memorynetwork (Bi-LSTM). For example, a coding characteristic representation304 after being coded by a Bi-LSTM model may be represented as:u _(1:n) ^(q)=[u ₁ ^(q) ,u ₂ ^(q) , . . . ,u _(n) ^(q)]=BILSTM ([v ₁^(q) ,v ₂ ^(q) , . . . ,v _(n) ^(q)])  (1)

where v_(1:n) ^(q)=[v₁ ^(q), v₂ ^(q), . . . , v_(n) ^(q)] represents thequestion 110 of which the length is n. In an example of FIG. 3, n=7, andu_(1:n) ^(q)=[u₁ ^(q), u₂ ^(q), . . . , u_(n) ^(q)] is a representationof v_(1:n) ^(q) after being coded by the Bi-LSTM model. v_(i) ^(q)∈

^(d), and d represents a dimension of a word vector. u_(i) ^(q)∈

^(2h), and h represents a number of neurons in a hidden layer of theBi-LSTM. In some embodiments, the computing device 130 may use thecoding characteristic representation 304 as the question characteristicrepresentation 310. By introducing the context information extracted bythe Bi-LSTM, the question characteristic representation 310 may betterrepresent a logicality among respective vocabularies in the question110.

In some embodiment, the computing device 130 may also combine u_(1:n)^(q) into a coding vector with a specific dimension. As illustrated inFIG. 3, the computing device 130 may calculate a weight α_(i) associatedwith the i^(-th) element u_(i) ^(q) in the coding characteristicrepresentation by utilizing a weight model 306 (for describingconveniently, referred as a first weight system below) and based oninformation of the coding characteristic representation 304, in which,α_(i)=softmax(r ^(T) tan h(w _(a) u _(i) ^(q)))  (2)

where the softmax function may ensure that a sum of elements in theweight vector α is 1, r and w_(α) may be adjusted by model training,which will be taken as a part of training parameters of the entiresystem 300 for training uniformly, and a detailed training procedurewill be described in detail below. In some embodiments, the computingdevice 130 may perform a weighted summation on u_(i) ^(q) by utilizingα_(i) respectively, to obtain a characteristic representation χ^(q) asthe question characteristic representation 310, in which,

$\begin{matrix}{\chi^{q} = {\sum\limits_{i = 1}^{n}{\alpha_{i}{u_{i}^{q}.}}}} & (3)\end{matrix}$

In embodiments of the present disclosure, respective elements in thecoding characteristic representation 304 are weighted by utilizing theweight model 306 to obtain the question characteristic representation310. The question characteristic representation 310 may better reflectthe importance of each vocabulary in the question 110 and reduce theextent to which certain irrelevant vocabularies affect the model.

Referring to FIG. 2 again, at block 204, the computing device 130determines a comment characteristic representation corresponding to acomment 120 for the object. In some embodiments, the computing device130 may receive the question 110 for the object firstly, and obtain thecomment 120 associated with the object. For example, in the example ofFIG. 1, the question 110 is a question for a product object “dress”, andthe computing device 130 may obtain the comment 120 associated with theproduct object “dress” from a default comment database. Alternatively,the computing device 130 may also extract the associated comment 120from a network webpage of the product object “dress”.

In some embodiments, the computing device 130 may filter out somecomment with low quality by the model. For example, the computing device130 may filter out junk comments that may be sent by a robot account,thus avoiding interference of junk comments on the answer.

A comment 120-1 “My 3 years old girl loved it.” will be taken as anexample to describe the procedure at block 204 below. In detail, asillustrated in FIG. 3, the computing device 130 may perform thesegmentation on the comment 120-1, to determine a second vocabularycharacteristic representation. As illustrated in FIG. 3, after thecomment 120-1 is obtained, the computing device 130 may perform thesegmentation on the comment 120-1 by utilizing a segmentation model.Similar to the procedure for performing the segmentation on the questionabove, when the comment is a pinyin such as English or Latin, asegmented result may be respective segmented words; and when the commentis Chinese or Japanese, a segmented result may be respective segmentedvocabularies. In detail, in the example illustrated in FIG. 3, asegmented result of the comment 120-1 is: “my”, “3”, “years”, “old”,“girl”, “loved”, and “it”. It should be understood that, any suitablesegmentation technology may be employed to perform the segmentation onthe comment 120-1, which is not elaborated herein.

Continuing to the example of FIG. 3, based on coding each word in thecomment 120-1, the second vocabulary characteristic representation ofthe comment 120-1 may be represented as [v₁ ^(r) ^(j) , v₂ ^(r) ^(j) , .. . , v_(n) ^(r) ^(j) ], where v_(i) ^(r) ^(j) is the i^(-th) word inthe j^(-th) comment. In some embodiments, the computing device 130 maytake the second vocabulary characteristic representation as the commentcharacteristic representation directly.

Referring to FIG. 2 again, at block 206, the computing device 130generates a target characteristic representation by utilizing thequestion characteristic representation and the comment characteristicrepresentation. In some embodiments, the computing device 130 maycombine each element in the second vocabulary characteristicrepresentation and the question characteristic representation to obtaina combination characteristic representation. In detail, as illustratedin FIG. 3, the computing device 130 may combine χ which represents thequestion characteristic representation 310 with each element 322 (codedon a word) of the comment characteristic representation of the comment120-1 to obtain a combination characteristic representation e. Thecombination characteristic representation e may be represented as e_(i)^(r) ^(j) =v_(i) ^(r) ^(j) ⊕χ. Therefore, the combination characteristicrepresentation may be represented ase _(1:n) ^(r) ^(j) =[e ₁ ^(r) ^(j) ,e ₂ ^(r) ^(j) , . . . ,e _(n) ^(r)^(j) ]=[v ₁ ^(r) ^(j) ,χ,v ₂ ^(r) ^(j) ,χ, . . . ,v _(n) ^(r) ^(j) ,χ](e_(i) ^(r) ^(j) ∈

^(d+2×h))  (4)

With such characteristic combination way, the solution of the presentdisclosure may not only consider an input question and related commentsat the same time, but also solve a disadvantage that the existingsolution is difficult to extract an effective feature from a short text,thereby improving the accuracy for responding a question.

In some embodiments, the computing device 130 may determine a targetcharacteristic representation 326 based on the combinationcharacteristic representation. In some embodiments, the computing device130 may take the combination characteristic representation as the targetcharacteristic representation directly.

In some embodiments, the computing device 130 may apply the combinationcharacteristic representation to a context extraction model, to obtainthe target characteristic representation, and the context extractionmodel is configured to determine a context relationship among elementsin the combination characteristic representation. For example, asillustrated in FIG. 3, the computing device 130 may extract contextinformation in the comment characteristic representation by utilizingthe Bi-LSTM. A coding characteristic representation ē_(1:n) ^(r) ^(j)after being coded by the Bi-LSTM may be represented as:ē _(1:n) ^(r) ^(j) =[ē ₁ ^(r) ^(j) ,ē ₂ ^(r) ^(j) , . . . ,ē _(n) ^(r)^(j) ]=BILSTM([e ₁ ^(r) ^(j) ,e ₂ ^(r) ^(j) , . . . ,e _(n) ^(r) ^(j)])  (5)

In some embodiments, the computing device 130 may take the codingcharacteristic representation ē_(1:n) ^(r) ^(j) as the targetcharacteristic representation. By introducing context informationextracted by the Bi-LSTM, the target characteristic representation maybetter reflect context information of respective vocabularies in thequestion 110 and in the comment 120-1.

In some embodiments, the computing device 130 may also determine aweight associated with each element in the combination characteristicrepresentation by utilizing a weight model 324, and weight each elementby utilizing the weight, to obtain the target characteristicrepresentation 326. For example, a weighted target characteristicrepresentation z^(r) ^(j) associated with the j^(-th) comment may berepresented as

$\begin{matrix}{z^{r_{j}} = {\sum\limits_{i = 1}^{n}{{{softmax}\left( {\theta^{T}{\tanh\left( {w_{\beta}{\overset{\_}{e}}_{i}^{r_{j}}} \right)}} \right)}{\overset{\_}{e}}_{i}^{r_{j}}}}} & (6)\end{matrix}$

where θ and w_(β) are adjustable parameters by training, which may betaken as a part of the training parameters of the entire system 300 fortraining uniformly. The detailed training procedure will be described indetail below.

The generation procedure of the target characteristic representation 326is described by utilizing only the comment 120-1 as an example.Similarly, the computing device 130 may generate a target characteristicrepresentation 336 associated with a second comment 120-2 and a targetcharacteristic representation 346 associated with the M^(th) comment120-M based on the question characteristic representation 310, thecomment 120-2 and the comment 120-M.

Referring to FIG. 2 again, at block 208, the computing device 130determines an answer for the question based on the target characteristicrepresentation. The detailed operation procedure of block 208 will bedescribed below with reference to FIG. 4. FIG. 4 is a flow chartillustrating a procedure 400 for determining an answer for a questionaccording to embodiments of the present disclosure.

At block 402, the computing device 130 determines a predictioncharacteristic representation for the first comment based on the firsttarget characteristic representation and a second target characteristicrepresentation associated with the second comment. In detail, thecomputing device 130 may extract support information of each piece ofcomment for other comments by a cross-voting inspection mechanism. Thesupport information s_(i,j) may be represented as:

$\begin{matrix}{s_{i,j} = \left\{ \begin{matrix}{{- \infty},} & {i = j} \\{{z^{r_{i}T} \cdot z^{r_{j}}},} & {i \neq j}\end{matrix} \right.} & (7)\end{matrix}$

According to s_(i,j), the computing device may calculate a contributionweight β_(i,j) (i.e., β_(i,j)=exp(s_(i,j))/Σ_(k=1) ^(n)s_(i,k)) of othercomments for the target comment. Further, the computing device 130 mayperform the weighted summation on z^(r) ^(j) by utilizing β, to obtain aprediction characteristic representation {tilde over (z)}^(r) ^(j)(i.e., {tilde over (z)}^(r) ^(j) =Σ_(i=1) ^(n)β_(i,j)·z^(r) ^(i) ) ofthe j^(-th) comment. In detail, for the first comment 120-1, thecomputing device 130 may calculate support information s_(2,1)=z^(r) ¹^(T)·z^(r) ² of the second comment 120-2 for the first comment 120-1based on a first target characteristic representation 326 z^(r) ¹ and asecond target characteristic representation 336 z^(r) ² .Correspondingly, a prediction characteristic representation 362 of thefirst comment 120-1 may be represented as:{tilde over (z)} ^(r) ¹ =Σ_(i=1) ^(n)β_(i,1) ·z ^(r) ^(i)   (8)

At block 404, the computing device 130 determines a differencecharacteristic representation based on the first target characteristicrepresentation and the prediction characteristic representation.Continuing to the example of FIG. 3, the computing device 130 mayperform not exclusive or operation on the first target characteristicrepresentation 326 and the prediction characteristic representation 362,that is, the difference characteristic representation 364 may berepresented as z^(r) ^(j) ⊙{tilde over (z)}^(r) ^(j) .

At block 406, the computing device 130 determines the answer 140 for thequestion based on the first target characteristic representation, theprediction characteristic representation and the differencecharacteristic representation. As illustrated in FIG. 3, the computingdevice 130 may determine a characteristic representation 360-1associated with the first comment 120-1, which may include three parts:the target characteristic representation 326, the predictioncharacteristic representation 362 and the difference characteristicrepresentation 364. For example, the characteristic representation 360(360-1, 360-2 . . . 360-M) may be represented as g^(r) ^(j) =[z^(r) ^(j), {tilde over (z)}^(r) ^(j) , z^(r) ^(j) ⊙{tilde over (z)}^(r) ^(j) ].In some embodiments, the computing device 130 may determine the answer140 for the question 110 based on a plurality of characteristicrepresentations 360 and by utilizing a logistic regression model. Basedon the same way, the technical solution of the present disclosure notonly considers the characteristic of the comment, but also considers thesupport information of other comments for the comment, thus improvingthe accuracy for predicting a question.

In some embodiments, the computing device 130 may select at least onecharacteristic from the first target characteristic representation, theprediction characteristic representation and the differencecharacteristic representation. For example, for accelerating to train amodel, the computing device 130 may utilize maxing pooling to select themost efficient one from each characteristic representation 360. Byperforming the maxing pooling on a plurality of characteristicrepresentations 360, the computing device 130 may obtain a maxingpooling characteristic representation 370, which may be represented asx=max-pooling[g ^(r) ¹ ,g ^(r) ² , . . . ,g ^(r) ^(m) ]  (9),

where x∈

^(m). In detail, as illustrated in FIG. 3, the characteristic 372 may beobtained by performing the maxing pooling on the characteristicrepresentation 360-1. Based on such way, the technical solution of thepresent disclosure may reduce the dimension of the training vector andaccelerate the training for the model while ensuring quality.

In some embodiments, the computing device 130 may determine an answer byutilizing the logistic regressive model based on the at least onecharacteristic. In detail, as illustrated in FIG. 3, the computingdevice 130 may perform processing on the maxing pooling characteristicrepresentation 370 by utilizing the logistic regression model, to obtainthe answer 140 of the question 110. For example, the prediction answer140 may be represented as

$\begin{matrix}{{\hat{y} = \frac{1}{1 + \exp - \left( {{w_{y}^{T}x} + b_{y}} \right)}},} & (10)\end{matrix}$

where ŷ represents a prediction answer of the apparatus for thequestion, and w_(y) and b_(y) are a parameter and an offset of thelogistic regression model respectively.

The using procedure of the system 300 is described above. In thetraining procedure, for training data with N samples, the computingdevice 130 may correspondingly predict a series of answer probabilities(ŷ₁, ŷ₂, . . . , ŷ_(n)). Comparing with an actual value, a loss in theprediction procedure may be marked as

$\begin{matrix}{L_{y} = {{\sum\limits_{i = 1}^{N}{\left( {y_{i} - 1} \right){\log\left( {1 - {\hat{y}}_{i}} \right)}}} - {y_{i}{{\log\left( {\hat{y}}_{l} \right)}.}}}} & (11)\end{matrix}$

In the training procedure, the computing device 130 may first randomlyinitialize the following parameter spaces: a parameter group in theBi-LSTM model, r, w_(α), θ and w_(β) in the weight model, and aparameter w_(y) and an offset b_(y) of a learning target. Next, thecomputing device 130 may send a plurality of pieces of training datainto the system 300 one by one or in batches. The input may be aquestion and comments corresponding to the question. A receiving end mayrespond the question truly, which may be represented as (0/1). Indetail, the computing device 130 may employ a stochastic gradientdescent algorithm to backtrack and to update the parameters layer bylayer, so as to gradually reduce the loss L_(y), which may be until theloss has been reduced to an acceptable level, or the number ofiterations has exceeded the preset number of times.

FIG. 5 is a block diagram illustrating an apparatus 500 for respondingto a question according to embodiments of the present disclosure. Theapparatus 500 may be included in the computing device 130 illustrated inFIG. 1, or implemented as the computing device 130. As illustrated inFIG. 5, the apparatus 500 includes a question characteristicrepresentation determining module 510, configured to determine aquestion characteristic representation corresponding to a question foran object. The apparatus 500 further includes a comment characteristicrepresentation determining module 520, configured to determine a commentcharacteristic representation corresponding to a first comment for theobject. The apparatus 500 further includes a target characteristicrepresentation generating module, configured to generate a first targetcharacteristic representation by utilizing the question characteristicrepresentation and the comment characteristic representation. Inaddition, the apparatus 500 further includes an answer determiningmodule 540, configured to determine an answer for the question based onthe first target characteristic representation.

In some embodiments, the apparatus 500 further includes: a commentobtaining module, configured to obtain the first comment associated withthe object in response to receiving the question for the object.

In some embodiments, the question characteristic representationdetermining module 510 includes: a first vocabulary characteristicrepresentation determining module and a first question characteristicrepresentation determining module. The first vocabulary characteristicrepresentation determining module is configured to determine a firstvocabulary characteristic representation by performing a segmentation onthe question. The first question characteristic representationdetermining module is configured to determine the questioncharacteristic representation based on the first vocabularycharacteristic representation.

In some embodiments, the first question characteristic representationdetermining module includes a first applying module, configured to applythe first vocabulary characteristic representation to a contextextraction model, to obtain the question characteristic representation.The context extraction model is configured to determine a contextrelationship among elements in the first vocabulary characteristicrepresentation.

In some embodiments, the comment characteristic representationdetermining module 520 includes: a second vocabulary characteristicrepresentation determining module and a first comment characteristicrepresentation determining module. The second vocabulary characteristicrepresentation determining module is configured to determine a secondvocabulary characteristic representation by performing a segmentation onthe comment. The first comment characteristic representation determiningmodule is configured to determine the comment characteristicrepresentation based on the second vocabulary characteristicrepresentation.

In some embodiments, the target characteristic representationdetermining module 530 includes: a combination determining module and afirst target characteristic representation determining module. Thecombination module is configured to combine each element in the secondvocabulary characteristic representation with the questioncharacteristic representation, to obtain a combination characteristicrepresentation. The first target characteristic representationdetermining module is configured to determine the first targetcharacteristic representation based on the combination characteristicrepresentation.

In some embodiments, the first target characteristic representationdetermining module includes: a second applying module, configured toapply the combination characteristic representation to a contextextraction model, to obtain the first target characteristicrepresentation. The context extraction model is configured to determinea context relationship among elements in the combination characteristicrepresentation.

In some embodiments, the first target characteristic representationdetermining module includes: a weight determining module and a weightingmodule. The weight determining module is configured to determine aweight associated with each element in the combination characteristicrepresentation by utilizing a weight model. The weighting module isconfigured to weight the element by utilizing the weight, to obtain thefirst target characteristic representation.

In some embodiments, the comment is a first comment, and the targetcharacteristic representation is the first target characteristicrepresentation. The apparatus 500 further includes: a second commentobtaining module, configured to obtain a second comment for the object.The answer determining module 540 includes: a prediction characteristicrepresentation determining module, a difference characteristicrepresentation determining module and a first answer determining module.The prediction characteristic representation determining module isconfigured to determine a prediction characteristic representation forthe first comment based on the first target characteristicrepresentation and a second target characteristic representationassociated with the second comment. The difference characteristicrepresentation determining module is configured to determine adifference characteristic representation based on the first targetcharacteristic representation and the prediction characteristicrepresentation. The first answer determining module is configured todetermine the answer for the question based on the first targetcharacteristic representation, the prediction characteristicrepresentation and the difference characteristic representation.

In some embodiments, the first answer determining module includes: acharacteristic selection determining module and a second answerdetermining module. The characteristic selection determining module isconfigured to select at least one characteristic representation of thefirst target characteristic representation, the predictioncharacteristic representation and the difference characteristicrepresentation. The second answer determining module is configured todetermine the answer by utilizing a regression model based on the atleast one characteristic representation.

FIG. 6 is a block diagram illustrating an exemplary device 600 forimplementing embodiments of the present disclosure. The device 600 maybe configured as the computing device 130 illustrated in FIG. 1. Asillustrated in FIG. 6, the device 600 includes a center processing unit(CPU) 601. The CPU 601 may execute various appropriate actions andprocesses according to computer program instructions stored in a readonly memory (ROM) 602 or computer program instructions loaded to arandom access memory (RAM) 603 from a storage unit 608. The RAM 603 mayalso store various programs and date required by the device 600. The CPU601, the ROM 602, and the RAM 603 may be connected to each other via abus 604. An input/output (I/O) interface 605 is also connected to thebus 604.

A plurality of components in the device 600 are connected to the I/Ointerface 605, including: an input unit 606 such as a keyboard, a mouse;an output unit 607 such as various types of displays, loudspeakers; astorage unit 608 such as a magnetic disk, an optical disk; and acommunication unit 609, such as a network card, a modem, a wirelesscommunication transceiver. The communication unit 609 allows the device600 to exchange information/data with other devices over a computernetwork such as the Internet and/or various telecommunication networks.

The processing unit 601 executes the above-mentioned methods andprocesses, such as the method 300. For example, in some embodiments, theprocedure 200 and/or the procedure 400 may be implemented as a computersoftware program. The computer software program is tangibly contained amachine readable medium, such as the storage unit 608. In someembodiments, a part or all of the computer programs of the computerprograms may be loaded and/or installed on the device 600 through theROM 602 and/or the communication unit 609. When the computer programsare loaded to the RAM 603 and are executed by the CPU 601, one or moreblocks of the procedure 200 and/or the procedure 400 described above maybe executed. Alternatively, in other embodiments, the CPU 601 may beconfigured to execute the procedure 200 and/or the procedure 400 inother appropriate ways (such as, by means of hardware).

The functions described herein may be executed at least partially by oneor more hardware logic components. For example, without not limitation,exemplary types of hardware logic components that may be used include: afield programmable gate array (FPGA), an application specific integratedcircuit (ASIC), an application specific standard product (ASSP), asystem on chip (SOC), a complex programmable logic device (CPLD) and thelike.

Program codes for implementing the method of the present disclosure maybe written in any combination of one or more programming languages.These program codes may be provided to a processor or a controller of ageneral purpose computer, a special purpose computer or otherprogrammable data processing device, such that the functions/operationsspecified in the flowcharts and/or the block diagrams are implementedwhen these program codes are executed by the processor or thecontroller. These program codes may execute entirely on a machine,partly on a machine, partially on the machine as a stand-alone softwarepackage and partially on a remote machine or entirely on a remotemachine or entirely on a server.

In the context of the present disclosure, the machine-readable mediummay be a tangible medium that may contain or store a program to be usedby or in connection with an instruction execution system, apparatus, ordevice. The machine-readable medium may be a machine-readable signalmedium or a machine-readable storage medium. The machine-readable mediummay include, but not limit to, an electronic, magnetic, optical,electromagnetic, infrared, or semiconductor system, apparatus, ordevice, or any suitable combination of the foregoing. More specificexamples of the machine-readable storage medium may include electricalconnections based on one or more wires, a portable computer disk, a harddisk, a RAM, a ROM, an erasable programmable read-only memory (EPROM orflash memory), an optical fiber, a portable compact disk read-onlymemory (CD-ROM), an optical storage, a magnetic storage device, or anysuitable combination of the foregoing.

In addition, although the operations are depicted in a particular order,it should be understood to require that such operations are executed inthe particular order illustrated in the drawings or in a sequentialorder, or that all illustrated operations should be executed to achievethe desired result. Multitasking and parallel processing may beadvantageous in certain circumstances. Likewise, although severalspecific embodiment details are included in the above discussion, theseshould not be construed as limitation of the scope of the presentdisclosure. Certain features described in the context of separateembodiments may also be implemented in combination in a singleimplementation. On the contrary, various features described in thecontext of the single implementation may also be implemented in aplurality of implementations, either individually or in any suitablesub-combination.

Although the subject matter has been described in language specific tostructural features and/or methodological acts, it should be understoodthat the subject matter defined in the appended claims is not limited tothe specific features or acts described above. Instead, the specificfeatures and acts described above are merely exemplary forms ofimplementing the claims.

What is claimed is:
 1. A method for responding to a question for anobject, comprising: determining a question characteristic representationcorresponding to the question for the object; determining a commentcharacteristic representation corresponding to a first comment for theobject; generating a first target characteristic representation byutilizing the question characteristic representation and the commentcharacteristic representation; and determining an answer for thequestion based on the first target characteristic representation.
 2. Themethod of claim 1, further comprising: obtaining the first commentassociated with the object in response to receiving the question for theobject.
 3. The method of claim 1, wherein, determining the questioncharacteristic representation comprises: determining a first vocabularycharacteristic representation by performing a segmentation on thequestion; and determining the question characteristic representationbased on the first vocabulary characteristic representation.
 4. Themethod of claim 3, wherein, determining the question characteristicrepresentation based on the first vocabulary characteristicrepresentation comprises: applying the first vocabulary characteristicrepresentation to a context extraction model, to obtain the questioncharacteristic representation, the context extraction model beingconfigured to determine a context relationship among elements in thefirst vocabulary characteristic representation.
 5. The method of claim1, wherein, determining the comment characteristic representationcomprises: determining a second vocabulary characteristic representationby performing a segmentation on the first comment; and determining thecomment characteristic representation based on the second vocabularycharacteristic representation.
 6. The method of claim 5, wherein,generating the first target characteristic representation comprises:combining each element in the second vocabulary characteristicrepresentation with the question characteristic representation, toobtain a combination characteristic representation; and determining thefirst target characteristic representation based on the combinationcharacteristic representation.
 7. The method of claim 6, wherein,determining the first target characteristic representation based on thecombination characteristic representation comprises: applying thecombination characteristic representation to a context extraction model,to obtain the first target characteristic representation, in which, thecontext extraction model is configured to determine a contextrelationship among elements in the combination characteristicrepresentation.
 8. The method of claim 6, wherein, determining the firsttarget characteristic representation based on the combinationcharacteristic representation comprises: determining a weight associatedwith an element in the combination characteristic representation byutilizing a weight model; and weighting the element in the combinationcharacteristic representation by utilizing the weight.
 9. The method ofclaim 1, further comprising: obtaining a second comment for the object;wherein determining the answer for the question comprises: determining aprediction characteristic representation for the first comment based onthe first target characteristic representation and a second targetcharacteristic representation associated with the second comment;determining a difference characteristic representation based on thefirst target characteristic representation and the predictioncharacteristic representation; and determining the answer for thequestion based on the first target characteristic representation, theprediction characteristic representation and the differencecharacteristic representation.
 10. The method of claim 9, wherein,determining the answer for the question based on the first targetcharacteristic representation, the prediction characteristicrepresentation and the difference characteristic representationcomprises: selecting at least one characteristic representation from thefirst target characteristic representation, the predictioncharacteristic representation and the difference characteristicrepresentation; and determining the answer by utilizing a regressionmodel based on the at least one characteristic representation.
 11. Anapparatus for responding to a question for an object, comprising: one ormore processors; a memory storing instructions executable by the one ormore processors; wherein the one or more processors are configured to:determine a question characteristic representation corresponding to thequestion for the object; determine a comment characteristicrepresentation corresponding to a first comment for the object; generatea first target characteristic representation by utilizing the questioncharacteristic representation and the comment characteristicrepresentation; and determine an answer for the question based on thefirst target characteristic representation.
 12. The apparatus of claim11, wherein the one or more processors are configured to: obtain thefirst comment associated with the object in response to receiving thequestion for the object.
 13. The apparatus of claim 11, wherein, the oneor more processors are configured to determine the questioncharacteristic representation by performing acts of: determining a firstvocabulary characteristic representation by performing a segmentation onthe question; and determining the question characteristic representationbased on the first vocabulary characteristic representation.
 14. Theapparatus of claim 12, wherein, the one or more processors areconfigured to determine the question characteristic representation basedon the first vocabulary characteristic representation by performing anact of: applying the first vocabulary characteristic representation to acontext extraction model, to obtain the question characteristicrepresentation, the context extraction model being configured todetermine a context relationship among elements in the first vocabularycharacteristic representation.
 15. The apparatus of claim 11, wherein,the one or more processors are configured to determine the commentcharacteristic representation by performing acts of: determining asecond vocabulary characteristic representation by performing asegmentation on the comment; and determining the comment characteristicrepresentation based on the second vocabulary characteristicrepresentation.
 16. The apparatus of claim 15, wherein, the one or moreprocessors are configured to generate the first target characteristicrepresentation by performing acts of: combining each element in thesecond vocabulary characteristic representation with the questioncharacteristic representation, to obtain a combination characteristicrepresentation; and determining the first target characteristicrepresentation based on the combination characteristic representation.17. The apparatus of claim 16, wherein, the one or more processors areconfigured to determine the first target characteristic representationbased on the combination characteristic representation by performing anact of: applying the combination characteristic representation to acontext extraction model, to obtain the first target characteristicrepresentation, in which, the context extraction model is configured todetermine a context relationship among elements in the combinationcharacteristic representation.
 18. The apparatus of claim 16, wherein,the one or more processors are configured to determine the first targetcharacteristic representation based on the combination characteristicrepresentation by performing acts of: determining a weight associatedwith an element in the combination characteristic representation byutilizing a weight model; and weighting the element in the combinationcharacteristic representation by utilizing the weight.
 19. The apparatusof claim 11, wherein the one or more processors are configured to obtaina second comment for the object; and the one or more processors areconfigured to determine the answer for the question by performing actsof: determining a prediction characteristic representation for the firstcomment based on the first target characteristic representation and asecond target characteristic representation associated with the secondcomment; determining a difference characteristic representation based onthe first target characteristic representation and the predictioncharacteristic representation; and determining the answer for thequestion based on the first target characteristic representation, theprediction characteristic representation and the differencecharacteristic representation.
 20. A non-transitory computer readablestorage medium having a computer program stored thereon that, whenexecuted by a processor, causes the processor to implement a method forresponding to a question for an object, wherein the method comprises:determining a question characteristic representation corresponding tothe question for the object; determining a comment characteristicrepresentation corresponding to a first comment for the object;generating a first target characteristic representation by utilizing thequestion characteristic representation and the comment characteristicrepresentation; and determining an answer for the question based on thefirst target characteristic representation.